import axios from '../api'
export const login = (email, password) => {
    return axios.request({
        url: '/login',
        method: 'post',
        data: {
            email,
            password
        }
    })
}
export const regisgter = (username, email, password) => {
    return axios.request({
        url: '/register',
        method: 'post',
        data: {
            username,
            email,
            password
        }
    })
}
export const logout = ()=>{
    return axios.request({
        url:'/logout',
        method:'get'
    })
}